package com.wennimei.util;

import java.beans.Introspector;

import org.springframework.beans.factory.config.BeanDefinition;
import org.springframework.context.annotation.AnnotationBeanNameGenerator;

/**
 * bean默认名字生成器
 * 
 * @author shichen.feng
 */
public class PackageAnnotationBeanNameGenerator extends
        AnnotationBeanNameGenerator {

    @Override
    protected String buildDefaultBeanName(BeanDefinition definition) {
        String name = Introspector.decapitalize(definition.getBeanClassName());
        return name;
    }
}
